package com.cskaoyan.mall25.exception;

import com.cskaoyan.mall25.bean.BaseRespVo;
import org.springframework.web.bind.annotation.ExceptionHandler;
import org.springframework.web.bind.annotation.RestControllerAdvice;

@RestControllerAdvice
public class CustomControllerAdvice {

    @ExceptionHandler(PermissionException.class)
    public BaseRespVo permission(){
        //return BaseRespVo.fail(506);
        return BaseRespVo.noPermission();
    }
}
